home *** CD-ROM | disk | FTP | other *** search
/ The CICA Windows Explosion! / The CICA Windows Explosion! - Disc 2.iso / programr / msdn200.zip / BWCC.H < prev    next >
C/C++ Source or Header  |  1993-12-02  |  5KB  |  194 lines

  1. // Borland Windows Custom Controls 
  2. // (C) Copyright 1991-1993 by Borland International
  3.  
  4. //
  5. // BWCC.H
  6. //
  7.  
  8. // Purpose:    Borland Windows Custom Controls  (BWCC)
  9.  
  10.  
  11. #if !defined(__BWCC_H)
  12. #define __BWCC_H
  13.  
  14. #ifndef RC_INVOKED
  15. #pragma warn -nak   /* Ignore non-ansi keywords */
  16. #endif
  17.  
  18. #if !defined(WORKSHOP_INVOKED)
  19.  
  20. #if !defined(__WINDOWS_H)
  21. #include <windows.h>
  22.  
  23. #endif
  24.  
  25. #endif
  26.  
  27. #define BWCCVERSION 0x0200   // version 2.00
  28.  
  29. // from version 1.02 onward BWCCGetversion returns a DWORD
  30. // The low-order word contains the version number
  31. // and the high-order word contains the locale
  32.  
  33. #define BWCC_LOCALE_US     1
  34. #define BWCC_LOCALE_JAPAN  2
  35.  
  36.  
  37. #define BORDLGPROP  "FB"      // Borland dialog window uses
  38.                               // this property for instance data
  39.                               // users should not use a property
  40.                               // with this name!
  41.  
  42. #define IDHELP    998         // Id of help button
  43.  
  44. #define BORDLGCLASS   "BorDlg"      // Our Custom Dialog class
  45. #define BORGRAYCLASS  "BorDlg_Gray" // Our Custom Dialog class - gray background
  46. #define BUTTON_CLASS  "BorBtn"    // Our Bitmap Buttons
  47. #define RADIO_CLASS   "BorRadio"  // Our Radio Buttons
  48. #define CHECK_CLASS   "BorCheck"  // Our Check Boxes
  49. #define STATIC_CLASS  "BorStatic" // Our statics
  50. #define SHADE_CLASS   "BorShade"  // Our Group Boxes and Dividers
  51.  
  52. #if !defined(EXPORT)
  53. #define EXPORT _export
  54. #endif
  55.  
  56. // The class names for Win32 are appended with "32" to distinguish
  57. // them from the Windows-16 classes in case we are running in Win32s
  58.  
  59. #if !defined(__FLAT__) && !defined(WIN32)
  60.  
  61. #define BWCCAPI FAR EXPORT PASCAL
  62.  
  63.  
  64. #else
  65.  
  66. #define BWCCAPI APIENTRY EXPORT
  67.  
  68. #endif
  69.  
  70. // button style definitions:
  71.  
  72. // the Borland buttons use Windows button styles for button
  73. // type: i.e. BS_PUSHBUTTON/BS_DEFPUSHBUTTON
  74.  
  75. // styles
  76.  
  77. #define BBS_BITMAP       0x8000L  // this is a bitmap static
  78. #define BBS_PARENTNOTIFY 0x2000L  // Notify parent of TAB keys and focus
  79. #define BBS_OWNERDRAW    0x1000L  // let parent paint via WM_DRAWITEM
  80.  
  81. // messages
  82.  
  83. #define BBM_SETBITS       ( BM_SETSTYLE + 10)
  84.  
  85. // notifications
  86.  
  87. #define BBN_SETFOCUS      ( BN_DOUBLECLICKED + 10)
  88. #define BBN_SETFOCUSMOUSE ( BN_DOUBLECLICKED + 11)
  89. #define BBN_GOTATAB       ( BN_DOUBLECLICKED + 12)
  90. #define BBN_GOTABTAB      ( BN_DOUBLECLICKED + 13)
  91. #define BBN_MOUSEENTER    ( BN_DOUBLECLICKED + 14)
  92. #define BBN_MOUSELEAVE    ( BN_DOUBLECLICKED + 14)
  93.  
  94.  
  95. // The following is the name of the window message passed to
  96. // RegisterWindowMessage for CtlColor processing for group box shades:
  97. #define BWCC_CtlColor_Shade "BWCC_CtlColor_Shade"
  98.  
  99. #define BSS_GROUP     1L  // recessed group box
  100. #define BSS_HDIP      2L  // horizontal border
  101. #define BSS_VDIP      3L  // vertical border
  102. #define BSS_HBUMP     4L  // horizontal speed bump
  103. #define BSS_VBUMP     5L  // vertical speed bump
  104. #define BSS_RGROUP    6L  // raised group box
  105.  
  106. #define BSS_CAPTION   0x8000L // Set off the caption
  107. #define BSS_CTLCOLOR  0x4000L // Send WM_CTLCOLOR messages to parent of control
  108. #define BSS_NOPREFIX  0x2000L // & in caption does not underline following letter
  109. #define BSS_LEFT      0x0000L // Caption is left-justified
  110. #define BSS_CENTER    0x0100L // Caption is centered
  111. #define BSS_RIGHT     0x0200L // Caption is right-justified
  112. #define BSS_ALIGNMASK 0x0300L
  113.  
  114.  
  115. #if defined( __cplusplus )
  116. extern "C" {
  117. #endif  /* __cplusplus */
  118.  
  119. extern HGLOBAL BWCCAPI SpecialLoadDialog
  120. (
  121.  
  122.   HINSTANCE   hResMod,
  123.   LPCSTR      lpResName,
  124.   DLGPROC     fpDlgProc
  125. );
  126.  
  127. extern HGLOBAL BWCCAPI MangleDialog
  128. (
  129.   HGLOBAL     hDlg,
  130.   HINSTANCE   hResources,
  131.   DLGPROC     fpDialogProc
  132. );
  133.  
  134. extern LRESULT BWCCAPI BWCCDefDlgProc
  135. (
  136.   HWND        hWnd,
  137.   UINT        message,
  138.   WPARAM      wParam,
  139.   LPARAM      lParam
  140. );
  141. extern LRESULT BWCCAPI BWCCDefGrayDlgProc
  142. (
  143.   HWND        hWnd,
  144.   UINT        message,
  145.   WPARAM      wParam,
  146.   LPARAM      lParam
  147. );
  148.  
  149.  
  150. extern LRESULT BWCCAPI BWCCDefWindowProc
  151. (
  152.   HWND        hWnd,
  153.   UINT        message,
  154.   WPARAM      wParam,
  155.   LPARAM      lParam
  156. );
  157.  
  158. extern LRESULT BWCCAPI BWCCDefMDIChildProc
  159. (
  160.   HWND        hWnd,
  161.   UINT        message,
  162.   WPARAM      wParam,
  163.   LPARAM      lParam
  164. );
  165.  
  166. extern int BWCCAPI BWCCMessageBox
  167. (
  168.   HWND        hWndParent,
  169.   LPCSTR      lpText,
  170.   LPCSTR      lpCaption,
  171.   UINT        wType
  172. );
  173.  
  174.  
  175. extern HBRUSH BWCCAPI BWCCGetPattern( void );
  176.  
  177. extern DWORD BWCCAPI BWCCGetVersion( void);
  178.  
  179. extern BOOL BWCCAPI BWCCIntlInit (UINT language);
  180.  
  181. extern BOOL BWCCAPI BWCCIntlTerm ( VOID );
  182.  
  183. extern BOOL BWCCAPI BWCCRegister(HINSTANCE hInsta);
  184.  
  185. #if defined( __cplusplus )
  186. }
  187. #endif  /* __cplusplus */
  188.  
  189. #ifndef RC_INVOKED
  190. #pragma warn .nak   /* Ignore non-ansi keywords */
  191. #endif
  192.  
  193. #endif  /* __BWCC_H */
  194.